-
-
Notifications
You must be signed in to change notification settings - Fork 231
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(breaking): Add ClassTag, improve Effect.serviceConstants, require string identifier for all tags #2028
Conversation
🦋 Changeset detectedLatest commit: c74d900 The changes in this PR will be included in the next version bump. This PR includes changesets to release 18 packages
Not sure what this means? Click here to learn what changesets are. Click here if you're a maintainer who wants to add another changeset to this PR |
|
As a follow up I propose renaming |
Some more ideas to infer the shape from the make effect; https://github.com/effect-ts-app/libs/blob/34c0458a3e9e5a42b723260802785ce369ee07d5/packages/prelude/_src/service.ts#L72 |
24040f2
to
4100ce4
Compare
Not sure I understand your suggestion, please provide a code snippet |
4100ce4
to
f523f01
Compare
…e string identifier for all tags
f523f01
to
ee39ab3
Compare
@mikearnaldi - big fan of this - simplifies a lot of boilerplate around Nice work 👍 |
Looks good! Agree with the renaming too. Quick fix to ensure the definition stack is set correctly: #2029 |
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
…e string identifier for all tags (#2028) Co-authored-by: Tim <hello@timsmart.co>
With this change we now require a string key to be provided for all tags and renames the dear old
Tag
toGenericTag
, so when previously you could do:you are now mandated to do:
This makes by default all tags globals and ensures better debuggaility when unexpected errors arise.
Furthermore we introduce a new way of constructing tags that should be considered the new default:
this will use "Service" as the key and will create automatically an opaque identifier (the class) to be used at the type level, it does something similar to the above in a single shot.